/**
 * mockSuggestList --> get_all_suggest()
 */
const mockSuggestList = async () => {
  return {
    data: [
      {
        name: "北林用户1",
        message: "12345",
      },
      {
        name: "北林用户2",
        message: "12345",
      },
      {
        name: "北林用户3",
        message: "12345",
      },
    ],
  };
};

/**
 * 展示当前用户列表，包括前面两种用户以及注册了的企业用户  --> get_all_user()
 */
const mockUsersList = async () => {
  return {
    data: [
      {
        id: "12345678",
        name: "北林用户",
        distinct: "",
        status: "1",
      },
      {
        id: "12345678",
        name: "北林用户",
        distinct: "",
        status: "2",
      },
      {
        id: "12345678",
        name: "北林用户",
        distinct: "",
        status: "1",
      },
    ],
  };
};

/**
 * 
 * --> get_all_unregistered_user()
 */
const mockCompanyUserToRegister = async () => {
  return {
    data: [
      {
        id: "12345678",
        name: "企业用户1",
        distinct: "",
        company: "",
        legal: "",
      },
      {
        id: "12345678",
        name: "企业用户2",
        distinct: "",
        company: "",
        legal: "",
      },
      {
        id: "12345678",
        name: "企业用户3",
        distinct: "",
        company: "",
        legal: "",
      },
    ],
  };
};

/**
 * 
 * --> get_all_factor()
 */
const mockFactorObj = async () => {
  return {
    data: {
      key1: 123,
      key2: 345,
      key3: 456,
    },
  };
};


/**
 * 
 * --> get_post_all_comment()
 */
const mockUserDiscussion = async () => {
  return {
    data: [
      {
        evaluationID: "1234567",
        userMessage: ["很好的结果", "这个结果还可以", "很好的结果"],
      },
      {
        evaluationID: "123456789",
        userMessage: [
          "很好的结果",
          "这个结果还可以",
          "很坏的结果",
          "我觉得123456789的结果有待商榷",
        ],
      },
    ],
  };
};

/**
 * 用于测试的对象
 */
const mockHandler = {
  mockSuggestList,
  mockUsersList,
  mockCompanyUserToRegister,
  mockFactorObj,
  mockUserDiscussion,
};

export { mockHandler };
